#ifndef NANO_V1_H
#define NANO_V1_H

#include <godot_cpp/classes/node.hpp>
#include <godot_cpp/variant/utility_functions.hpp>
#include <godot_cpp/variant/packed_byte_array.hpp>
#include <godot_cpp/core/binder_common.hpp>


#include "../protocol/protocol.h"
#include "../package/nano_package.h"
#include "../message/nano_message.h"

namespace godot {

class NanoV1 : public Object{
	GDCLASS(NanoV1, Object)

private:


protected:
	static void _bind_methods();

public:
	static PackedByteArray encodeStr(const String& p_str);
	static String decodeStr(const PackedByteArray& p_data);
	static PackedByteArray encodePackage(const Ref<NanoPackage>& p_pkg);
	static Array decodePackage(const PackedByteArray& p_data);
	static PackedByteArray encodeMessage(const Ref<NanoMessage>& p_msg);
	static Ref<NanoMessage> decodeMessage(const PackedByteArray& p_data);

};

}



#endif